package com.idealighter.game.games.weishuwu.struct;

/**
 * 魏蜀吴下注类型.
 */
public enum BettingDecision {

  SHU_PAIRE(0, "蜀对"), WU_PAIRE(1, "吴对"), SHU(2, "蜀"), WEI(3, "魏"), WU(4, "吴"), SHU_HU_JIANG(5,
      "蜀虎将"), DA_NIU(6, "大牛阵"), XIAO_MA(7, "小马阵"), WU_DU_DU(8, "吴都督"),;

  public final int type;
  public final String desc;

  BettingDecision(int type, String desc) {
    this.type = type;
    this.desc = desc;
  }

  /**
   * .
   * 
   * @param type 类型.
   * @return
   */
  public static BettingDecision getBettingType(int type) {
    for (BettingDecision betType : BettingDecision.values()) {
      if (betType.type == type) {
        return betType;
      }
    }
    return null;
  }

  @Override
  public String toString() {

    return name() + "(" + desc + ")";
  }
}
